This description relates to automatically generating formulas based on parameters of a model.
Various types of application software can be used for analytical computations for a given application such as business or engineering. For example, software such as spreadsheets, modeling software, business intelligence platforms, and database software can be used for building analytical models and performing associated computations on application data.
Spreadsheets allow a user to manage data within cells of the spreadsheet and analyze the data by populating cells with formulas that can refer to values in other cells and perform operations and functions on those values. In some spreadsheet software, data records from sources such as a “flat table” within the spreadsheet or from an external database source, for example, can be analyzed in a “pivot table” within the spreadsheet. A flat table has columns representing fields labeled across a top row and a series of rows representing individual records having values for the different fields. In one example of a pivot table a left-most column has different values or ranges of values for a first field (e.g., products or regions), and a top-most row has different values or ranges of values for a second field (e.g., time periods such as months), and each cell at the intersection of given values of the first and second fields (e.g., a given product and a given month) represents a value for a third field (e.g., revenue) computed based on an aggregation of the records for the given values of the first and second fields (e.g., sum of revenue from all records representing transactions for a given product in a given month). The pivot table can also include subtotals for multiple rows or columns (e.g., revenue for a given quarter). The fields represented in the pivot table can be easily swapped.
Modeling software allows a user to define variables that can be used in mathematical expressions and can be assigned a single value for a scalar variable, or multiple values for a variable associated with a dimension such as time. Expressions using these variables can be computed and the results presented as graphical representations such as tables having rows and columns similar to a spreadsheet, with a given series of cell values being computed based on expressions evaluated at different values of the time dimension. Some modeling software can also generate spreadsheets as output.